
import org.junit.Test;

import static org.junit.Assert.assertEquals;

public class TestTriangle {
    @Test
    public void testTriangle() {
        Triangle triangle = new Triangle();
        String type = triangle.classify(3, 4, 6);
        assertEquals("一般三角形", type);
    }

    @Test
    public void testTriangle_dengbian() {
        Triangle triangle = new Triangle();
        String type = triangle.classify(5, 5, 5);
        assertEquals("等边三角形", type);
    }

    @Test
    public void testTriangle_dengyao() {
        Triangle triangle = new Triangle();
        String type = triangle.classify(4, 4, 6);
        assertEquals("等腰三角形", type);
    }

    @Test
    public void testTriangle_fei() {
        Triangle triangle = new Triangle();
        String type = triangle.classify(2, 4, 2);
        assertEquals("非三角形", type);
    }

}
